<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>

    <script>

        // 条件语句?表达式1:表达式2 

        //   if(){只有一句代码} else {只有一句代码}   --- 改写成三目运算符

        // var a = 2 ;
        // a > 0 ? console.log('正数'):console.log('不是正数') ;






    </script>
    
</body>
</html>